package com.tnovoselec.android.travelassistant.adapter;

import android.content.Context;

import com.tnovoselec.android.travelassistant.Constant;
import com.tnovoselec.android.travelassistant.R;
import com.tnovoselec.android.travelassistant.dto.IGeoPoint;

public class BankomatiAdapter extends AbstractAdapter<IGeoPoint> {

	public BankomatiAdapter(Context context) {
		super(context);
	}

	@Override
	protected int getLogoImageResource(IGeoPoint item) {
		if (item.getBank_id().toLowerCase().contains(Constant.HPB_REGEX)) {
			return R.drawable.hpb_icon;
		} else if (item.getBank_id().toLowerCase().contains(Constant.PBZ_REGEX)) {
			return R.drawable.pbz_icon;
		} else if (item.getBank_id().toLowerCase().contains(Constant.ZABA_REGEX)) {
			return R.drawable.zaba_icon;
		} else if (item.getBank_id().toLowerCase().contains(Constant.ERSTE_REGEX)) {
			return R.drawable.erste_icon;
		} else if (item.getBank_id().toLowerCase().contains(Constant.OTP_REGEX)) {
			return R.drawable.otp_icon;
		} else if (item.getBank_id().toLowerCase().contains(Constant.SPLITSKA_REGEX)) {
			return R.drawable.splitska_icon;
		} else if (item.getBank_id().toLowerCase().contains(Constant.HYPO_REGEX)) {
			return R.drawable.hypo_icon;
		} else if (item.getBank_id().toLowerCase().contains(Constant.RBA_REGEX)) {
			return R.drawable.rba_icon;
		} else {
			return -1;
		}
	}

}
